home *** CD-ROM | disk | FTP | other *** search
/ Skunkware 98 / Skunkware 98.iso / src / mail / pine3.96.tar.gz / pine3.96.tar / pine3.96 / imap / non-ANSI / c-client / mh.h < prev    next >
C/C++ Source or Header  |  1994-08-15  |  4KB  |  136 lines

  1. /*
  2.  * Program:    MH mail routines
  3.  *
  4.  * Author(s):    Mark Crispin
  5.  *        Networks and Distributed Computing
  6.  *        Computing & Communications
  7.  *        University of Washington
  8.  *        Administration Building, AG-44
  9.  *        Seattle, WA  98195
  10.  *        Internet: MRC@CAC.Washington.EDU
  11.  *
  12.  * Date:    23 February 1992
  13.  * Last Edited:    14 August 1994
  14.  *
  15.  * Copyright 1994 by the University of Washington
  16.  *
  17.  *  Permission to use, copy, modify, and distribute this software and its
  18.  * documentation for any purpose and without fee is hereby granted, provided
  19.  * that the above copyright notice appears in all copies and that both the
  20.  * above copyright notice and this permission notice appear in supporting
  21.  * documentation, and that the name of the University of Washington not be
  22.  * used in advertising or publicity pertaining to distribution of the software
  23.  * without specific, written prior permission.  This software is made
  24.  * available "as is", and
  25.  * THE UNIVERSITY OF WASHINGTON DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED,
  26.  * WITH REGARD TO THIS SOFTWARE, INCLUDING WITHOUT LIMITATION ALL IMPLIED
  27.  * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE, AND IN
  28.  * NO EVENT SHALL THE UNIVERSITY OF WASHINGTON BE LIABLE FOR ANY SPECIAL,
  29.  * INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
  30.  * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, TORT
  31.  * (INCLUDING NEGLIGENCE) OR STRICT LIABILITY, ARISING OUT OF OR IN CONNECTION
  32.  * WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
  33.  *
  34.  */
  35.  
  36. /* Build parameters */
  37.  
  38. #define MHPROFILE ".mh_profile"
  39. #define MHPATH "Mail"
  40.  
  41.  
  42. /* Command bits from mh_getflags() */
  43.  
  44. #define fSEEN 1
  45. #define fDELETED 2
  46. #define fFLAGGED 4
  47. #define fANSWERED 8
  48.  
  49.  
  50. /* MH I/O stream local data */
  51.  
  52. typedef struct mh_local {
  53.   unsigned int inbox : 1;    /* if it's an INBOX or not */
  54.   char *dir;            /* spool directory name */
  55.   char *buf;            /* temporary buffer */
  56.   char *hdr;            /* current header */
  57.   unsigned long buflen;        /* current size of temporary buffer */
  58.   time_t scantime;        /* last time directory scanned */
  59. } MHLOCAL;
  60.  
  61.  
  62. /* Convenient access to local data */
  63.  
  64. #define LOCAL ((MHLOCAL *) stream->local)
  65.  
  66. /* Function prototypes */
  67.  
  68. DRIVER *mh_valid  ();
  69. int mh_isvalid  ();
  70. void *mh_parameters  ();
  71. void mh_find  ();
  72. void mh_find_bboards  ();
  73. void mh_find_all  ();
  74. void mh_find_all_bboards  ();
  75. long mh_subscribe  ();
  76. long mh_unsubscribe  ();
  77. long mh_subscribe_bboard  ();
  78. long mh_unsubscribe_bboard  ();
  79. long mh_create  ();
  80. long mh_delete  ();
  81. long mh_rename  ();
  82. MAILSTREAM *mh_open  ();
  83. void mh_close  ();
  84. void mh_fetchfast  ();
  85. void mh_fetchflags  ();
  86. ENVELOPE *mh_fetchstructure  ();
  87. char *mh_fetchheader  ();
  88. char *mh_fetchtext  ();
  89. char *mh_fetchbody  ();
  90. void mh_setflag  ();
  91. void mh_clearflag  ();
  92. void mh_search  ();
  93. long mh_ping  ();
  94. void mh_check  ();
  95. void mh_expunge  ();
  96. long mh_copy  ();
  97. long mh_move  ();
  98. long mh_append  ();
  99. void mh_gc  ();
  100.  
  101. int mh_select  ();
  102. int mh_numsort  ();
  103. char *mh_file  ();
  104. short mh_getflags  ();
  105. char mh_search_all  ();
  106. char mh_search_answered  ();
  107. char mh_search_deleted  ();
  108. char mh_search_flagged  ();
  109. char mh_search_keyword  ();
  110. char mh_search_new  ();
  111. char mh_search_old  ();
  112. char mh_search_recent  ();
  113. char mh_search_seen  ();
  114. char mh_search_unanswered  ();
  115. char mh_search_undeleted  ();
  116. char mh_search_unflagged  ();
  117. char mh_search_unkeyword  ();
  118. char mh_search_unseen  ();
  119. char mh_search_before  ();
  120. char mh_search_on  ();
  121. char mh_search_since  ();
  122. unsigned long mh_msgdate  ();
  123. char mh_search_body  ();
  124. char mh_search_subject  ();
  125. char mh_search_text  ();
  126. char mh_search_bcc  ();
  127. char mh_search_cc  ();
  128. char mh_search_from  ();
  129. char mh_search_to  ();
  130. typedef char (*search_t)  ();
  131. search_t mh_search_date  ();
  132. search_t mh_search_flag  ();
  133. search_t mh_search_string  ();
  134.  
  135. char *bezerk_snarf  ();
  136.